package com.example.bourse.filter.exception;

import com.example.bourse.core.enums.ReqCodeEnum;

/**
 * @author wangzhiqi
 * @version 1.0
 * @description: 路由路径异常
 * @date 2025/1/21 12:05
 */
public class RootPathException extends RuntimeException {
    private final int code;

    public RootPathException(int code, String message) {
        super(message);
        this.code = code;
    }

    public RootPathException(String message) {
        super(message);
        this.code = ReqCodeEnum.CUSTOM_EXCEPTION.getCode();
    }

    public int getCode() {
        return code;
    }
}
